lib=libmymath.a

$(lib):mymath.o
#	ar -rc libmymath.a mymath.o 
# ar为归档工具 rc表示 replace and creat
	ar -rc $@ $^


mymath.o:mymath.c

	gcc -c $^

.PHONY:clean
clean:
	rm -rf *.a *.o lib

.PHONY:output
output:
	mkdir -p lib/include
	mkdir -p lib/mymathlib
	cp *.h lib/include
	cp *.a lib/mymathlib